<%@ page language="java" pageEncoding="UTF-8"%>
<div class="modal fade bs-example-modal-lg"  aria-labelledby="myLargeModalLabel" aria-hidden="true">
<div class="modal-dialog modal-lg">
<div class="modal-content">
<div id="allmap" style="width: 900px;height: 550px;font-family:'微软雅黑';font-size:14px;"></div>

</div>
</div>
</div>
<script type="text/javascript">
	//百度地图API功能
	var map;
	function loadJScript() {
		var script = document.createElement("script");
		script.type = "text/javascript";
		script.src = "http://api.map.baidu.com/api?v=2.0&ak=qzAAxn8ifTRDGP2Wl8AoHGDj&callback=init";
		document.body.appendChild(script);
	}
	function init() {
		map = new BMap.Map("allmap");            // 创建Map实例
		map.centerAndZoom(new BMap.Point(105.901507,29.353885), 15);
		map.setCurrentCity("永川");
		map.enableScrollWheelZoom(true);
	}
	window.onload = loadJScript;  //异步加载地图
	function line(l) {
		var busline = new BMap.BusLineSearch(map,{
			renderOptions:{map:map,panel:""},
				onGetBusListComplete: function(result){
				   if(result) {
					 var fstLine = result.getBusListItem(0);//获取第一个公交列表显示到map上
					 busline.getBusLine(fstLine);
				   }
				}
		});
		busline.getBusList("永川"+l);
	}
	
</script>
